package com.yidu.manage.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.yidu.manage.domain.SysDictData;
import com.yidu.manage.mapper.ISysDictDataMapper;
import com.yidu.manage.mapper.ISysDictTypeMapper;
import com.yidu.manage.service.ISysDictTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SysDictTypeServiceImpl implements ISysDictTypeService
{
    @Autowired
    private ISysDictDataMapper sysDictDataMapper;

    @Override
    public List<SysDictData> selectDictDataByType(String dictType)
    {
        QueryWrapper<SysDictData> wrapper = new QueryWrapper<>();
        wrapper.eq("dict_type", dictType);
        return sysDictDataMapper.selectList(wrapper);
    }
}
